﻿using System;
using System.Collections.Generic;
using System.IO;

namespace Zjh.PackSerializer
{
    public interface IPackSerializer
    {
        byte[] Serialize<T>(T obj);

        byte[] Serialize(Type objectType, object obj);

        void Serialize(Stream stream, Type objectType, object obj);

        T Deserialize<T>(byte[] buffer);

        object Deserialize(byte[] buffer, Type objectType);

        object Deserialize(Stream stream, Type objectType);
    }
}